﻿using Logic;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using System;
using System.Runtime.Remoting.Metadata.W3cXsd2001;

namespace TestProject1
{


    /// <summary>
    ///This is a test class for ChallengePAKTest and is intended
    ///to contain all ChallengePAKTest Unit Tests
    ///</summary>
    [TestClass()]
    public class ChallengePAKTest
    {


        private TestContext testContextInstance;

        /// <summary>
        ///Gets or sets the test context which provides
        ///information about and functionality for the current test run.
        ///</summary>
        public TestContext TestContext
        {
            get
            {
                return testContextInstance;
            }
            set
            {
                testContextInstance = value;
            }
        }

        #region Additional test attributes
        // 
        //You can use the following additional attributes as you write your tests:
        //
        //Use ClassInitialize to run code before running the first test in the class
        //[ClassInitialize()]
        //public static void MyClassInitialize(TestContext testContext)
        //{
        //}
        //
        //Use ClassCleanup to run code after all tests in a class have run
        //[ClassCleanup()]
        //public static void MyClassCleanup()
        //{
        //}
        //
        //Use TestInitialize to run code before running each test
        //[TestInitialize()]
        //public void MyTestInitialize()
        //{
        //}
        //
        //Use TestCleanup to run code after each test has run
        //[TestCleanup()]
        //public void MyTestCleanup()
        //{
        //}
        //
        #endregion


        /// <summary>
        ///A test for CRC16_163
        ///</summary>
        [TestMethod()]
        [DeploymentItem("Logic.dll")]
        public void CRC16_163Test()
        {
            ChallengePAK_Accessor target = new ChallengePAK_Accessor(); // TODO: Initialize to an appropriate value
            byte[] data = SoapHexBinary.Parse("23 49 6e 31 23 48").Value; ; // TODO: Initialize to an appropriate value
            int length = data.Length; // TODO: Initialize to an appropriate value
            ushort expected = 0; // TODO: Initialize to an appropriate value
            ushort actual;
            int target120 = 0xbc8e;
            string targetstring = target120.ToString("X");

            actual = target.CRC16_163(data, length);
            Assert.AreEqual(expected, actual);
            Assert.Inconclusive("Verify the correctness of this test method.");
        }
    }
}
